package com.twu.biblioteca.command;

import com.twu.biblioteca.service.MovieService;
import com.twu.biblioteca.view.MessageView;

public class ShowAvailableMovies extends Command{
    private MovieService movieService;

    public ShowAvailableMovies(MovieService movieService, MessageView messageView) {
        super(messageView);
        this.movieService = movieService;
    }

    @Override
    public void execute() {
        getMessageView().showMessageList(movieService.getMovieNames(movieService.getAvailableMovies()));
    }
}
